﻿<%@ Page Title="" Language="C#" MasterPageFile="~/admin/Admin.Master" AutoEventWireup="true"
    CodeBehind="createAdmin.aspx.cs" Inherits="PHTShop.admin.createAdmin" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <script type="text/javascript">
        $(function () {
            $('.removeBorder td').css('border', 'none');
            $('.removeBorder').css('width', '100%');
        });

        function Checknumber(sender, args) {
            var num = document.getElementById('<%=txtPhone.ClientID %>').value;

            if (isNaN(num)) {
                args.IsValid = false;
            }
            else {

                args.IsValid = true;
            }

        }
    </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div id="title" class="b2">
        <h2>
            Create account</h2>
    </div>
    <fieldset>
        <legend>
            <asp:Label ID="lblInformation" runat="server" Font-Bold="true" Text="Account information"></asp:Label></legend>
            <label id="lblmesage" runat="server" style="color:Red"></label>
        <table class="removeBorder" style="width: 100%; border: none">
            <tr>
                <td>
                    <asp:Label ID="lblUsername" runat="server" Text="Username:"></asp:Label>
                </td>
                <td>
                   
                        <input type="text" title="Fusce elementum" id="txtUsername" runat="server" name="field1c"
                            class="text" />
                        <span class="required-icon tooltip">Required</span>
                    
                  
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="txtUsername"
                        Display="Dynamic" ErrorMessage="RequiredFieldValidator">Requirement</asp:RequiredFieldValidator>
                      
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="lblPassword" runat="server" Text="Password:"></asp:Label>
                </td>
                <td>
                    <input type="password" title="Fusce elementum" id="txtNewPassword" runat="server"
                        name="field1c" class="text" />
                    <span class="required-icon tooltip">Required</span>
                
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator6" runat="server" ControlToValidate="txtNewPassword"
                        Display="Dynamic" ErrorMessage="RequiredFieldValidator">Requirement</asp:RequiredFieldValidator>
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="lblComfirmPassword" runat="server" Text="Confirm :"></asp:Label>
                </td>
                <td>
                    <input type="password" title="Fusce elementum" id="txtConfirmPassword" runat="server"
                        name="field1c" class="text" />
                    <span class="required-icon tooltip">Required</span>
               
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator7" runat="server" ControlToValidate="txtConfirmPassword"
                        Display="Dynamic" ErrorMessage="RequiredFieldValidator">Requirement</asp:RequiredFieldValidator>
                    <asp:CompareValidator ID="CompareValidator1" runat="server" ControlToCompare="txtNewPassword"
                        ControlToValidate="txtConfirmPassword" Display="Dynamic" ErrorMessage="CompareValidator">Confirm New Password</asp:CompareValidator>
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="lblFullName" runat="server" Text="Full name:"></asp:Label>
                </td>
                <td>
                    <input type="text" title="Fusce elementum" id="txtFullName" runat="server" name="field1c"
                        class="text" />
                    <span class="required-icon tooltip">Required</span>
               
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ControlToValidate="txtFullName"
                        Display="Dynamic" ErrorMessage="RequiredFieldValidator">Requirement</asp:RequiredFieldValidator>
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="lblEmail" runat="server" Text="Email:"></asp:Label>
                </td>
                <td>
                    <input type="text" title="Fusce elementum" id="txtEmail" runat="server" name="field1c"
                        class="text" />
                    <span class="required-icon tooltip">Required</span>
                
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator8" runat="server" ControlToValidate="txtEmail"
                        Display="Dynamic" ErrorMessage="RequiredFieldValidator">Requirement</asp:RequiredFieldValidator>
                    <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" ControlToValidate="txtEmail"
                        Display="Dynamic" ErrorMessage="emai is not valid format" ValidationExpression="\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"></asp:RegularExpressionValidator>
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="lblAddress" runat="server" Text="Address:"></asp:Label>
                </td>
                <td>
                    <input type="text" title="Fusce elementum" id="txtAddress" runat="server" name="field1c"
                        class="text" />
                    <span class="required-icon tooltip">Required</span>
                
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" ControlToValidate="txtAddress"
                        Display="Dynamic" ErrorMessage="RequiredFieldValidator">Requirement</asp:RequiredFieldValidator>
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="lblPhone" runat="server" Text="Phone:"></asp:Label>
                </td>
                <td>
                    <input type="text" title="Fusce elementum" id="txtPhone" runat="server" name="field1c"
                        class="text" />
                    <span class="required-icon tooltip">Required</span>
                
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator5" runat="server" ControlToValidate="txtPhone"
                        ErrorMessage="RequiredFieldValidator" Display="Dynamic">Requirement</asp:RequiredFieldValidator>
                    <asp:CustomValidator ID="CustomValidator1" runat="server" ClientValidationFunction="Checknumber"
                        ControlToValidate="txtPhone" Display="Dynamic" ErrorMessage="CustomValidator">Numberic only</asp:CustomValidator>
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="lblRole" runat="server" Text="Role:"></asp:Label>
                </td>
                <td>
                    <asp:RadioButtonList ID="RadioButtonList1" runat="server" BorderWidth="0" 
                        RepeatDirection="Horizontal" RepeatLayout="Flow" CellSpacing="5">
                    <asp:ListItem Selected="True" Text="Admin    &nbsp;" Value="1"></asp:ListItem>  
                       
                    <asp:ListItem  Text="User" Value="2"></asp:ListItem>
                    </asp:RadioButtonList>
              
                  
                </td>
            </tr>
             <tr>
                <td>
                    <asp:Label ID="Label1" runat="server" Text="Active:"></asp:Label>
                </td>
                <td>
                    <asp:CheckBox ID="CheckBox1" runat="server" Checked="true" />
                </td>
              
            </tr>
            <tr>
                <td>
                </td>
                <td align="center">
                    <asp:Button ID="btnOK" CssClass="css_btn_class" runat="server" Text="Create" OnClick="btnOK_Click" />
                    &nbsp;
                    <input type="reset" value="Cancel" class="css_btn_class" />
                </td>
                <td>
                </td>
            </tr>
        </table>
    </fieldset>
</asp:Content>
